package com.orderplus.opshop.synces.entity.product;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.util.Date;

/**
 * Created by zhouxj6112 on 2019/1/5.
 */
@Data
@TableName("product_property")
@EqualsAndHashCode(callSuper=false)
public class ProductProperty extends Model<ProductProperty> {

    @TableId(value = "property_id", type = IdType.AUTO)
    private Integer propertyId;
    @TableField("from")
    private String from;
    @TableField("base_category_id")
    private Integer baseCategoryId;
    @TableField("property_key")
    private String propertyKey;
    @TableField("property_key_zh")
    private String propertyKeyZh;
    @TableField("property_key_th")
    private String propertyKeyTh;
    @TableField("property_key_id")
    private String propertyKeyId;
    @TableField("create_time")
    private Date createTime;
    @TableField("update_time")
    private Date updateTime;
    @TableField(exist = false)
    private String baseCategoryName;

    @Override
    protected Serializable pkVal() {
        return this.propertyId;
    }
}
